package com.ysd.lis.controller.inv;

import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.request.inv.FindReagentStockByBatchParam;
import com.ysd.lis.request.inv.InvReagentStockExpiryParam;
import com.ysd.lis.request.inv.InvReagentStockParam;
import com.ysd.lis.service.inv.InvReagentStockService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author prs
 * @since 2024-09-21
 */
@Api(tags = "试剂库存")
@RestController
@RequestMapping("/inv/invReagentStock")
public class InvReagentStockController extends BaseController {
    @Autowired
    InvReagentStockService invReagentStockService;

    @ApiOperation("查询")
    @GetMapping("/findReagentStockList")
    public Result findReagentStockList(InvReagentStockParam param) {
        return invReagentStockService.findReagentStockList(param);
    }

    @ApiOperation("高储查询")
    @GetMapping("/findHighStorageList")
    public Result findHighStorageList(InvReagentStockParam param) {
        return invReagentStockService.findHighStorageList(param);
    }

    @ApiOperation("低储查询")
    @GetMapping("/findLowStorageList")
    public Result findLowStorageList(InvReagentStockParam param) {
        return invReagentStockService.findLowStorageList(param);
    }

    @ApiOperation("效期查询")
    @GetMapping("/findReagentStockExpiryList")
    public Result findReagentStockExpiryList(InvReagentStockExpiryParam param) {
        return invReagentStockService.findReagentStockExpiryList(param);
    }

    @ApiOperation("批次查询")
    @GetMapping("/findReagentStockByBatch")
    public Result findReagentStockByBatch(FindReagentStockByBatchParam input) {
        return invReagentStockService.findReagentStockByBatch(input);
    }

    @ApiOperation("库存前十查询")
    @GetMapping("/findStockToprList")
    public Result findStockToprList(InvReagentStockParam param) {
        return invReagentStockService.findStockToprList(param);
    }

    @ApiOperation("失效查询")
    @GetMapping("/findStockExpiryList")
    public Result findStockExpiryList(InvReagentStockParam param) {
        return invReagentStockService.findStockExpiryList(param);
    }
}
